package com.song.service.impl;

import com.song.dao.StudentDao;
import com.song.model.Student;
import com.song.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;

/**
 * @ClassName : StudentServiceImpl
 * @Author : 司猫子
 * @Date: 2021/3/1 18:35
 */
@Controller
public class StudentServiceImpl implements StudentService {
    @Autowired
    private StudentDao studentDao;

    @Override
    public int addStudent(String name, Integer age) {
        return studentDao.addStudent(name, age);
    }

    @Override
    public Student queryById(Integer id) {
        return studentDao.queryById(id);
    }
}
